﻿using SqlSugar;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace DongFangGuoKai.WMSPlatform.Domain.Models
{
    [SugarTable("t_ApiLog")]
    public class PMSLog
    {
        /// <summary>
        /// Id
        /// </summary>
        [SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
        public int Id { get; set; }
        /// <summary>
        /// 请求开始时间
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(20)")]
        public string? StartTime { get; set; }
        /// <summary>
        /// 请求结束时间
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(20)")]

        public string? EndTime { get; set; }
        /// <summary>
        /// 执行毫秒数
        /// </summary>
        public long ExecuteTime { get; set; }

        /// <summary>
        /// 控制器名称
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(100)")]

        public string? ControllerName { get; set; }

        /// <summary>
        /// 方法名称
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(100)")]

        public string? ActionName { get; set; }

        /// <summary>
        /// 请求实体序列化
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(400)")]

        public string? RequestBody { get; set; }
        /// <summary>
        /// 响应实体序列化
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(400)")]

        public string? ResponsBody { get; set; }

        /// <summary>
        /// 请求路径
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(100)")]
        public string? RequestPath { get; set; }


        /// <summary>
        /// 客户端IP
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(50)")]
        public string? ClientIp { get; set; }
        /// <summary>
        ///  请求方法类型
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(10)")]
        public string? MethodType { get; set; }
        /// <summary>
        /// 用户Id
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(10)")]
        public string? UserId { get; set; }
        /// <summary>
        /// 用户名称
        /// </summary>
        [SugarColumn(ColumnDataType = "Nvarchar(10)")]
        public string? UserName { get; set; }
    }
}
